<?php

namespace common\models\patient;

use Yii;

/**
 * This is the model class for table "{{%patient_medical_records}}".
 *
 * @property int $id
 * @property int $project_id 项目ID
 * @property int $patient_user_id 用户ID
 * @property int $sick_time 生病时间
 * @property string $main_desc 主诉
 * @property string $now_medical_history 现病史
 * @property string $allergy_history 过敏史
 * @property string $jw_history 既往史
 * @property string $person_history 个人史
 * @property string $family_history 家族史
 * @property string $physique_history 体格检查
 * @property string $diagnose 诊断
 * @property string $auxiliary_result 辅助检查结果
 * @property string $clinic_opinion 治疗意见
 * @property int $patient_diseases_id 病种ID
 * @property string $diseases_name 诊断【病种名】
 * @property int $operate_id 操作者ID
 * @property int $created_at 添加时间
 * @property int $updated_at 更新时间
 */
class MedicalRecords extends \common\models\BaseModel
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return '{{%patient_medical_records}}';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['project_id', 'patient_user_id', 'sick_time', 'patient_diseases_id', 'operate_id', 'created_at', 'updated_at'], 'integer'],
            [['diseases_name'], 'string', 'max' => 60],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'project_id' => '项目ID',
            'patient_user_id' => '用户ID',
            'sick_time' => '生病时间',
            'main_desc' => '主诉',
            'now_medical_history' => '现病史',
            'allergy_history' => '过敏史',
            'jw_history' => '既往史',
            'person_history' => '个人史',
            'family_history' => '家族史',
            'physique_history' => '体格检查',
            'diagnose' => '诊断',
            'auxiliary_result' => '辅助检查结果',
            'clinic_opinion' => '治疗意见',
            'patient_diseases_id' => '病种ID',
            'diseases_name' => '诊断【病种名】',
            'operate_id' => '操作者ID',
            'created_at' => '添加时间',
            'updated_at' => '更新时间',
        ];
    }
}
